package com.sumainfor.wx.system.maket.controller.rentadviser;

import com.sumainfor.common.util.JsonResult;
import com.sumainfor.wx.system.maket.service.RdTenantAskService;
import org.apache.commons.compress.compressors.z.ZCompressorInputStream;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;
import java.util.Map;

/**
 * <p>
 *
 * <p>
 *
 * @author: zc
 * @create: 2019-08-27 14:12
 **/
@Controller
@RequestMapping("/RdTenantAskController")
public class RdTenantAskController {

    @Autowired
    RdTenantAskService rdTenantAskService;


    /**
     * 根据租客编号查询客户的接待记录
     * @author zhoucong
     * @data 2019/8/27
     * @Param
     * @return
     */
    @ResponseBody
    @GetMapping("/getTenantAskListByTenId")
    public JsonResult getTenantAskListByTenId(@RequestParam Map<String,Object> params){
        JsonResult result=new JsonResult();
        List<Map<String,Object>> list=rdTenantAskService.getTenantAskListByTenId(params);
        if (list!=null){
            result.put(list);
        }else{
            result.putFailed("服务器繁忙");
        }
        return result;
    }
}
